<template lang="">
    <div :style="{ color }">
        {{ modelValue }}
    </div>
    <input v-model="val" />
</template>
<script>
export default {
    props: ['modelValue', 'color'],
    data() {
        return {
            val: ''
        }
    },
    watch: {
        val() {
            this.setStr()
        }
    },
    methods: {
        setStr() {
            this.$emit('update:modelValue', this.val)
        }
    }
}
</script>
<style lang="">
    
</style>